package com.ryskoo.catering.vendortemplatereldetail.repository;

import com.ryskoo.catering.vendortemplatereldetail.domain.VendorTemplateRelDetailPO;
import com.ryskoo.framework.core.repository.IBasicRepository;

import java.util.List;

public interface IVendorTemplateRelDetailRepository extends IBasicRepository<VendorTemplateRelDetailPO> {

    /**
     * 根据关联主表uuids删除关联明细
     *
     * @param mainUuids
     */
    void deleteByMainUuids(List<String> mainUuids);

    /**
     * 根据主表uuid获取明细集合
     *
     * @param mainUuid  关联主表的uuid
     * @param useStatus boolean 是否使用状态来查询
     * @param status    boolean 状态值
     * @return
     */
    List<VendorTemplateRelDetailPO> getByMainUuid(String mainUuid, boolean useStatus, boolean status);

    /**
     * 设置某条关联明细的启用状态
     *
     * @param detailUuid
     * @param status
     */
    void changeStatus(String detailUuid, boolean status);

}
